#ifndef __POS_TIMER_H__
#define __POS_TIMER_H__

#define SYS_FWDGT 
//#define SYS_WWDGT   

extern volatile unsigned int Time13_Count;
extern volatile unsigned int Time13_Count2;
extern volatile unsigned int Time14_Count;
extern volatile unsigned int Time14_Count2;
extern volatile unsigned int Time15_Count;
extern volatile unsigned int G_PulseCount;
extern volatile unsigned int G_PulseCount2;
extern volatile unsigned int PulseCounted;
extern volatile unsigned int PulseTimeOut;

extern volatile unsigned int G_PulseCount12;
extern volatile unsigned int G_PulseCount12_1;   
extern volatile unsigned int PulseTimeOut12;

extern volatile unsigned char G_Standby;

void init_timer13(void);
void init_exti_Hall();
#ifdef DUAL_MODE
    void init_exti12(void);
    void EXTI12_Run(unsigned char Aon);
    void SetPulseCounter_12(unsigned char AOn);
#endif
void init_timer14(void);
void init_timer15(void);
// void OnTime ( void );
// void OnTime1 ( void );
// void OnPulse ( void );
void CheckStandby();
void DoSleepWakeUpTask();

void Timer13_Run(unsigned char Aon);
void SetTime13_Counter(unsigned char AOn);
void Timer14_Run(unsigned char Aon);
void SetTime14_Counter(unsigned char AOn);
void SetPulseCounter(unsigned char AOn);

#ifdef SYS_FWDGT
    void Fwdgt_Init(void);
#endif

// #ifdef SYS_WWDGT
//     void Wwdgt_Init(void);
// #endif

#endif